package com.motiontheory.inttest;

public class MockPropScene {
	private String propClassId;
	private double scale;
	private Boolean flipped;
	private double rotation;
	
	private int x;
	private int y;
	
	private String[] propIds = {"jean_butterfly_v3",
	                    "jean_butterfly_v6",
	                    "Scream_2",
	                    "jyoo-03"};
	
	public MockPropScene() {
		this.propClassId = propIds[((int) (Math.random() * 100)) % (propIds.length)];
		this.scale = Math.random();
		this.flipped = ((((int) (Math.random() * 100)) % 2) == 1) ? true : false;
		this.rotation = Math.random() * ((((int) (Math.random() * 100)) % 3) - 1);
		this.x = ((int) (Math.random() * 10000)) % 300;
		this.y = ((int) (Math.random() * 10000)) % 300;
	}
	
	public String getPropClassId ()
    {
    	return propClassId;
    }
    public void setPropClassId ( String propClass )
    {
    	this.propClassId = propClass;
    }
	public double getScale ()
    {
    	return scale;
    }
    public void setScale ( double sc )
    {
    	this.scale = sc;
    }	
	public boolean getFlipped ()
    {
    	return flipped;
    }
    public void setFlipped ( Boolean flip )
    {
    	this.flipped = flip;
    }
	public double getRotation ()
    {
    	return rotation;
    }
    public void setRotation ( double rot )
    {
    	this.rotation = rot;
    }	
	public int getX ()
    {
    	return x;
    }
    public void setX ( int x_ )
    {
    	this.x = x_;
    }	
	public int getY ()
    {
    	return y;
    }
    public void setY ( int y_ )
    {
    	this.y = y_;
    }	
    
    
    public String toJson(){

    	String jsonForm = "{\"propClassId\":\"" + getPropClassId() +
    			"\",\"scale\":" + getScale() +
    			",\"flipped\":" + getFlipped() +
    			",\"rotation\":" + getRotation() +
    			",\"center\":{\"x\":" + getX() +
    			",\"y\":" + getY() +
    			"}}";
    	return jsonForm;
    }
    
    
}
